package c.h.a.m0;

import android.annotation.SuppressLint;
import android.app.ActivityManager;
import android.bluetooth.BluetoothAdapter;
import android.content.Context;
import android.content.res.Configuration;
import android.database.Cursor;
import android.hardware.Sensor;
import android.hardware.SensorManager;
import android.hardware.camera2.CameraCharacteristics;
import android.hardware.camera2.CameraCharacteristics.Key;
import android.hardware.camera2.params.StreamConfigurationMap;
import android.net.Uri;
import android.os.Build;
import android.os.Build.VERSION;
import android.os.Environment;
import android.provider.Settings.Secure;
import android.provider.Settings.SettingNotFoundException;
import android.provider.Settings.System;
import android.text.TextUtils;
import android.text.format.Formatter;
import android.util.Range;
import android.util.Rational;
import android.util.Size;
import android.util.SizeF;
import c.b.a.a.a;
import c.h.a.d0.f;
import com.google.android.gms.dynamite.descriptors.com.google.android.gms.measurement.dynamite.ModuleDescriptor;
import com.huawei.hms.adapter.internal.AvailableCode;
import com.huawei.hms.android.HwBuildEx.VersionCodes;
import com.huawei.hms.api.ConnectionResult;
import com.huawei.hms.iap.entity.OrderStatusCode;
import com.liuzh.deviceinfo.DeviceInfoApp;
import java.io.File;
import java.net.NetworkInterface;
import java.text.DecimalFormat;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Date;
import java.util.List;
import java.util.Locale;
import java.util.Objects;
import java.util.TimeZone;
import java.util.concurrent.TimeUnit;

/* compiled from: GetDetails */
public class k {
    public static DecimalFormat a = new DecimalFormat("##.#");

    public static String A(Size size, int i) {
        float height = ((float) (size.getHeight() * size.getWidth())) / 1000000.0f;
        String str = " MP";
        StringBuilder stringBuilder;
        if (i == 1) {
            stringBuilder = new StringBuilder();
            stringBuilder.append(String.format(Locale.US, "%.1f", new Object[]{Float.valueOf(height)}));
            stringBuilder.append(str);
            return stringBuilder.toString();
        }
        String str2 = "%.2f";
        if (i == 2) {
            stringBuilder = new StringBuilder();
            stringBuilder.append(String.format(Locale.US, str2, new Object[]{Float.valueOf(height)}));
            stringBuilder.append(str);
            return stringBuilder.toString();
        }
        stringBuilder = new StringBuilder();
        stringBuilder.append(String.format(Locale.US, str2, new Object[]{Float.valueOf(height)}));
        stringBuilder.append(str);
        return stringBuilder.toString();
    }

    public static String B() {
        ActivityManager activityManager = (ActivityManager) DeviceInfoApp.c.getSystemService("activity");
        if (activityManager != null) {
            return activityManager.getDeviceConfigurationInfo().getGlEsVersion();
        }
        return DeviceInfoApp.c.getString(2131690514);
    }

    public static String C() {
        try {
            String property = System.getProperty("android.openssl.version");
            if (TextUtils.isEmpty(property)) {
                return DeviceInfoApp.c.getString(2131690514);
            }
            return property;
        } catch (Exception unused) {
            return DeviceInfoApp.c.getString(2131690514);
        }
    }

    /* JADX WARNING: Missing block: B:10:?, code skipped:
            r2.close();
     */
    /* JADX WARNING: Missing block: B:16:?, code skipped:
            r2.close();
     */
    public static java.lang.String D(android.content.Context r10) {
        /*
        r0 = "ndeviceinfo";
        r1 = new java.lang.StringBuilder;
        r1.<init>();
        r2 = new java.io.File;
        r3 = "/proc/cpuinfo";
        r2.<init>(r3);
        r2 = r2.exists();
        r4 = 2131690514; // 0x7f0f0412 float:1.9010074E38 double:1.0531950505E-314;
        if (r2 == 0) goto L_0x00be;
    L_0x0017:
        r2 = new java.io.BufferedReader;	 Catch:{ Exception -> 0x004f }
        r5 = new java.io.FileReader;	 Catch:{ Exception -> 0x004f }
        r6 = new java.io.File;	 Catch:{ Exception -> 0x004f }
        r6.<init>(r3);	 Catch:{ Exception -> 0x004f }
        r5.<init>(r6);	 Catch:{ Exception -> 0x004f }
        r2.<init>(r5);	 Catch:{ Exception -> 0x004f }
    L_0x0026:
        r3 = r2.readLine();	 Catch:{ all -> 0x0043 }
        if (r3 == 0) goto L_0x003f;
    L_0x002c:
        r5 = new java.lang.StringBuilder;	 Catch:{ all -> 0x0043 }
        r5.<init>();	 Catch:{ all -> 0x0043 }
        r5.append(r3);	 Catch:{ all -> 0x0043 }
        r5.append(r0);	 Catch:{ all -> 0x0043 }
        r3 = r5.toString();	 Catch:{ all -> 0x0043 }
        r1.append(r3);	 Catch:{ all -> 0x0043 }
        goto L_0x0026;
    L_0x003f:
        r2.close();	 Catch:{ Exception -> 0x004f }
        goto L_0x004f;
    L_0x0043:
        r3 = move-exception;
        throw r3;	 Catch:{ all -> 0x0045 }
    L_0x0045:
        r5 = move-exception;
        r2.close();	 Catch:{ all -> 0x004a }
        goto L_0x004e;
    L_0x004a:
        r2 = move-exception;
        r3.addSuppressed(r2);	 Catch:{ Exception -> 0x004f }
    L_0x004e:
        throw r5;	 Catch:{ Exception -> 0x004f }
    L_0x004f:
        r1 = r1.toString();
        r2 = ":";
        r1 = r1.split(r2);
        r2 = 0;
        r3 = 0;
    L_0x005b:
        r5 = r1.length;
        r6 = "";
        r7 = 1;
        if (r3 >= r5) goto L_0x0080;
    L_0x0061:
        r5 = r1[r3];
        r5 = r5.toLowerCase();
        r8 = "processor";
        r5 = r5.contains(r8);
        if (r5 == 0) goto L_0x007d;
    L_0x006f:
        r3 = r3 + r7;
        r5 = r1[r3];
        r5 = r5.indexOf(r0);
        r3 = r1[r3];
        r3 = r3.substring(r7, r5);
        goto L_0x0081;
    L_0x007d:
        r3 = r3 + 1;
        goto L_0x005b;
    L_0x0080:
        r3 = r6;
    L_0x0081:
        r5 = "0";
        r8 = r3.equals(r5);
        if (r8 != 0) goto L_0x008f;
    L_0x0089:
        r8 = r3.equals(r6);
        if (r8 == 0) goto L_0x00ad;
    L_0x008f:
        r8 = r1.length;
        if (r2 >= r8) goto L_0x00ad;
    L_0x0092:
        r8 = r1[r2];
        r9 = "model name";
        r8 = r8.contains(r9);
        if (r8 == 0) goto L_0x00aa;
    L_0x009c:
        r2 = r2 + r7;
        r3 = r1[r2];
        r0 = r3.indexOf(r0);
        r1 = r1[r2];
        r3 = r1.substring(r7, r0);
        goto L_0x00ad;
    L_0x00aa:
        r2 = r2 + 1;
        goto L_0x008f;
    L_0x00ad:
        r0 = r3.equals(r6);
        if (r0 != 0) goto L_0x00b9;
    L_0x00b3:
        r0 = r3.equals(r5);
        if (r0 == 0) goto L_0x00c2;
    L_0x00b9:
        r3 = r10.getString(r4);
        goto L_0x00c2;
    L_0x00be:
        r3 = r10.getString(r4);
    L_0x00c2:
        return r3;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.D(android.content.Context):java.lang.String");
    }

    public static String E(Range<Integer> range) {
        try {
            StringBuilder stringBuilder = new StringBuilder();
            stringBuilder.append("[");
            stringBuilder.append(((Integer) range.getLower()).toString());
            stringBuilder.append(",");
            stringBuilder.append(((Integer) range.getUpper()).toString());
            stringBuilder.append("]");
            return stringBuilder.toString();
        } catch (Exception unused) {
            return "";
        }
    }

    public static String F(Configuration configuration) {
        int i = configuration.orientation;
        if (i == 0) {
            return DeviceInfoApp.c.getString(2131690159);
        }
        if (i == 1) {
            return DeviceInfoApp.c.getString(2131690158);
        }
        if (i != 2) {
            return DeviceInfoApp.c.getString(2131690514);
        }
        return DeviceInfoApp.c.getString(2131690157);
    }

    public static String G(Configuration configuration) {
        DeviceInfoApp deviceInfoApp = DeviceInfoApp.c;
        int i = configuration.screenLayout & 15;
        if (i == 1) {
            return deviceInfoApp.getString(2131690389);
        }
        if (i == 2) {
            return deviceInfoApp.getString(2131690134);
        }
        if (i == 3) {
            return deviceInfoApp.getString(2131690037);
        }
        if (i != 4) {
            return deviceInfoApp.getString(2131690514);
        }
        return deviceInfoApp.getString(2131690573);
    }

    public static String H() {
        try {
            int i = System.getInt(DeviceInfoApp.c.getContentResolver(), "screen_off_timeout");
            StringBuilder stringBuilder = new StringBuilder();
            stringBuilder.append(i / 1000);
            stringBuilder.append(" ");
            stringBuilder.append(DeviceInfoApp.c.getString(2131690282));
            return stringBuilder.toString();
        } catch (SettingNotFoundException unused) {
            return DeviceInfoApp.c.getString(2131690514);
        }
    }

    public static String[] I(Context context) {
        String str = System.getenv("SECONDARY_STORAGE");
        ArrayList arrayList = new ArrayList();
        File[] externalFilesDirs = context.getExternalFilesDirs(null);
        if (externalFilesDirs == null || externalFilesDirs.length == 0) {
            return null;
        }
        for (File file : externalFilesDirs) {
            if (file != null) {
                Object obj = file.getPath().split("/Android")[0];
                if (Environment.isExternalStorageRemovable(file) || (str != null && str.contains(obj))) {
                    arrayList.add(obj);
                }
            }
        }
        return (String[]) arrayList.toArray(new String[0]);
    }

    public static String J(int i) {
        return DeviceInfoApp.c.getString(i);
    }

    public static String K() {
        StringBuilder stringBuilder = new StringBuilder();
        int i = 0;
        while (true) {
            String[] strArr = Build.SUPPORTED_ABIS;
            if (i >= strArr.length) {
                return stringBuilder.substring(0, stringBuilder.length() - 2);
            }
            stringBuilder.append(strArr[i]);
            stringBuilder.append(", ");
            i++;
        }
    }

    public static String L(long j) {
        if (j < 0) {
            return "00:00:00";
        }
        TimeUnit timeUnit = TimeUnit.MILLISECONDS;
        long toHours = timeUnit.toHours(j);
        long toMinutes = timeUnit.toMinutes(j);
        return String.format(Locale.getDefault(), "%02d:%02d:%02d", new Object[]{Long.valueOf(toHours), Long.valueOf(toMinutes - TimeUnit.HOURS.toMinutes(toHours)), Long.valueOf(timeUnit.toSeconds(j) - TimeUnit.MINUTES.toSeconds(toMinutes))});
    }

    public static String M() {
        TimeZone timeZone = TimeZone.getDefault();
        boolean inDaylightTime = timeZone.inDaylightTime(new Date());
        String displayName = timeZone.getDisplayName(inDaylightTime, 1);
        if (displayName == null || displayName.length() <= 0) {
            return timeZone.getDisplayName();
        }
        String str;
        int rawOffset = timeZone.getRawOffset();
        if (inDaylightTime) {
            rawOffset += timeZone.getDSTSavings();
        }
        rawOffset /= OrderStatusCode.ORDER_STATE_CANCEL;
        if (rawOffset < 0) {
            rawOffset = Math.abs(rawOffset);
            str = "-";
        } else {
            str = "+";
        }
        StringBuilder g = a.g(displayName);
        g.append(String.format(Locale.getDefault(), "(GMT%s%02d:%02d)", new Object[]{str, Integer.valueOf(rawOffset / 60), Integer.valueOf(rawOffset % 60)}));
        return g.toString();
    }

    public static String N() {
        String string = DeviceInfoApp.c.getString(2131690514);
        try {
            String str = "wlan0";
            for (NetworkInterface networkInterface : Collections.list(NetworkInterface.getNetworkInterfaces())) {
                if (networkInterface.getName().equalsIgnoreCase(str)) {
                    byte[] hardwareAddress = networkInterface.getHardwareAddress();
                    if (hardwareAddress == null) {
                        return string;
                    }
                    StringBuilder stringBuilder = new StringBuilder();
                    int length = hardwareAddress.length;
                    for (int i = 0; i < length; i++) {
                        stringBuilder.append(String.format("%02X:", new Object[]{Byte.valueOf(hardwareAddress[i])}));
                    }
                    if (stringBuilder.length() > 0) {
                        stringBuilder.deleteCharAt(stringBuilder.length() - 1);
                    }
                    String trim = stringBuilder.toString().trim();
                    if (TextUtils.isEmpty(trim)) {
                        return string;
                    }
                    string = trim;
                }
            }
        } catch (Exception unused) {
        }
        return string;
    }

    public static boolean O() {
        String str = Build.TAGS;
        return (str != null && str.contains("test-keys")) || d("/system/xbin/which su") || d("/system/bin/which su") || d("which su");
    }

    /* JADX WARNING: Missing block: B:15:?, code skipped:
            r4.close();
     */
    public static java.util.ArrayList<c.h.a.d0.c> P() {
        /*
        r0 = " ";
        r1 = new java.util.ArrayList;
        r1.<init>();
        r2 = 0;
    L_0x0008:
        r3 = java.lang.Runtime.getRuntime();
        r3 = r3.availableProcessors();
        if (r2 >= r3) goto L_0x00ad;
    L_0x0012:
        r3 = 2131689765; // 0x7f0f0125 float:1.9008555E38 double:1.0531946805E-314;
        r4 = new java.io.RandomAccessFile;	 Catch:{ Exception -> 0x0082 }
        r5 = new java.lang.StringBuilder;	 Catch:{ Exception -> 0x0082 }
        r5.<init>();	 Catch:{ Exception -> 0x0082 }
        r6 = "/sys/devices/system/cpu/cpu";
        r5.append(r6);	 Catch:{ Exception -> 0x0082 }
        r5.append(r2);	 Catch:{ Exception -> 0x0082 }
        r6 = "/cpufreq/scaling_cur_freq";
        r5.append(r6);	 Catch:{ Exception -> 0x0082 }
        r5 = r5.toString();	 Catch:{ Exception -> 0x0082 }
        r6 = "r";
        r4.<init>(r5, r6);	 Catch:{ Exception -> 0x0082 }
        r5 = r4.readLine();	 Catch:{ all -> 0x0076 }
        r5 = java.lang.Double.parseDouble(r5);	 Catch:{ all -> 0x0076 }
        r7 = 4652007308841189376; // 0x408f400000000000 float:0.0 double:1000.0;
        r5 = r5 / r7;
        r7 = new c.h.a.d0.c;	 Catch:{ all -> 0x0076 }
        r8 = new java.lang.StringBuilder;	 Catch:{ all -> 0x0076 }
        r8.<init>();	 Catch:{ all -> 0x0076 }
        r9 = J(r3);	 Catch:{ all -> 0x0076 }
        r8.append(r9);	 Catch:{ all -> 0x0076 }
        r8.append(r0);	 Catch:{ all -> 0x0076 }
        r9 = r2 + 1;
        r8.append(r9);	 Catch:{ all -> 0x0076 }
        r8 = r8.toString();	 Catch:{ all -> 0x0076 }
        r9 = new java.lang.StringBuilder;	 Catch:{ all -> 0x0076 }
        r9.<init>();	 Catch:{ all -> 0x0076 }
        r5 = (int) r5;	 Catch:{ all -> 0x0076 }
        r9.append(r5);	 Catch:{ all -> 0x0076 }
        r5 = " Mhz";
        r9.append(r5);	 Catch:{ all -> 0x0076 }
        r5 = r9.toString();	 Catch:{ all -> 0x0076 }
        r7.m1954init(r8, r5);	 Catch:{ all -> 0x0076 }
        r1.add(r7);	 Catch:{ all -> 0x0076 }
        r4.close();	 Catch:{ Exception -> 0x0082 }
        goto L_0x00a9;
    L_0x0076:
        r5 = move-exception;
        throw r5;	 Catch:{ all -> 0x0078 }
    L_0x0078:
        r6 = move-exception;
        r4.close();	 Catch:{ all -> 0x007d }
        goto L_0x0081;
    L_0x007d:
        r4 = move-exception;
        r5.addSuppressed(r4);	 Catch:{ Exception -> 0x0082 }
    L_0x0081:
        throw r6;	 Catch:{ Exception -> 0x0082 }
    L_0x0082:
        r4 = new c.h.a.d0.c;
        r5 = new java.lang.StringBuilder;
        r5.<init>();
        r3 = J(r3);
        r5.append(r3);
        r5.append(r0);
        r3 = r2 + 1;
        r5.append(r3);
        r3 = r5.toString();
        r5 = 2131690002; // 0x7f0f0212 float:1.9009035E38 double:1.0531947976E-314;
        r5 = J(r5);
        r4.m1954init(r3, r5);
        r1.add(r4);
    L_0x00a9:
        r2 = r2 + 1;
        goto L_0x0008;
    L_0x00ad:
        return r1;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.P():java.util.ArrayList");
    }

    /* JADX WARNING: Missing block: B:26:?, code skipped:
            r6.close();
     */
    /* JADX WARNING: Missing block: B:27:0x0090, code skipped:
            r6 = move-exception;
     */
    /* JADX WARNING: Missing block: B:29:?, code skipped:
            r4.addSuppressed(r6);
     */
    /* JADX WARNING: Missing block: B:36:?, code skipped:
            r5.close();
     */
    public static java.util.ArrayList<c.h.a.d0.g> Q() {
        /*
        r0 = new java.util.ArrayList;
        r0.<init>();
        r1 = new java.io.File;
        r2 = "/sys/devices/virtual/thermal/";
        r1.<init>(r2);
        r1 = r1.listFiles();
        if (r1 == 0) goto L_0x00a5;
    L_0x0012:
        r2 = r1.length;
        r3 = 0;
    L_0x0014:
        if (r3 >= r2) goto L_0x00a5;
    L_0x0016:
        r4 = r1[r3];
        r5 = new java.io.BufferedReader;	 Catch:{ IOException -> 0x00a1 }
        r6 = new java.io.FileReader;	 Catch:{ IOException -> 0x00a1 }
        r7 = new java.lang.StringBuilder;	 Catch:{ IOException -> 0x00a1 }
        r7.<init>();	 Catch:{ IOException -> 0x00a1 }
        r8 = r4.getAbsolutePath();	 Catch:{ IOException -> 0x00a1 }
        r7.append(r8);	 Catch:{ IOException -> 0x00a1 }
        r8 = "/temp";
        r7.append(r8);	 Catch:{ IOException -> 0x00a1 }
        r7 = r7.toString();	 Catch:{ IOException -> 0x00a1 }
        r6.<init>(r7);	 Catch:{ IOException -> 0x00a1 }
        r5.<init>(r6);	 Catch:{ IOException -> 0x00a1 }
        r6 = new java.io.BufferedReader;	 Catch:{ all -> 0x0095 }
        r7 = new java.io.FileReader;	 Catch:{ all -> 0x0095 }
        r8 = new java.lang.StringBuilder;	 Catch:{ all -> 0x0095 }
        r8.<init>();	 Catch:{ all -> 0x0095 }
        r4 = r4.getAbsolutePath();	 Catch:{ all -> 0x0095 }
        r8.append(r4);	 Catch:{ all -> 0x0095 }
        r4 = "/type";
        r8.append(r4);	 Catch:{ all -> 0x0095 }
        r4 = r8.toString();	 Catch:{ all -> 0x0095 }
        r7.<init>(r4);	 Catch:{ all -> 0x0095 }
        r6.<init>(r7);	 Catch:{ all -> 0x0095 }
        r4 = r6.readLine();	 Catch:{ all -> 0x0089 }
        r7 = r5.readLine();	 Catch:{ all -> 0x0089 }
        r8 = android.text.TextUtils.isEmpty(r7);	 Catch:{ all -> 0x0089 }
        if (r8 != 0) goto L_0x0082;
    L_0x0064:
        r8 = r7.trim();	 Catch:{ all -> 0x0089 }
        r9 = "0";
        r8 = r8.equals(r9);	 Catch:{ all -> 0x0089 }
        if (r8 != 0) goto L_0x0082;
    L_0x0070:
        r7 = s(r7);	 Catch:{ all -> 0x0089 }
        r8 = android.text.TextUtils.isEmpty(r7);	 Catch:{ all -> 0x0089 }
        if (r8 != 0) goto L_0x0082;
    L_0x007a:
        r8 = new c.h.a.d0.g;	 Catch:{ all -> 0x0089 }
        r8.m1958init(r4, r7);	 Catch:{ all -> 0x0089 }
        r0.add(r8);	 Catch:{ all -> 0x0089 }
    L_0x0082:
        r6.close();	 Catch:{ all -> 0x0095 }
        r5.close();	 Catch:{ IOException -> 0x00a1 }
        goto L_0x00a1;
    L_0x0089:
        r4 = move-exception;
        throw r4;	 Catch:{ all -> 0x008b }
    L_0x008b:
        r7 = move-exception;
        r6.close();	 Catch:{ all -> 0x0090 }
        goto L_0x0094;
    L_0x0090:
        r6 = move-exception;
        r4.addSuppressed(r6);	 Catch:{ all -> 0x0095 }
    L_0x0094:
        throw r7;	 Catch:{ all -> 0x0095 }
    L_0x0095:
        r4 = move-exception;
        throw r4;	 Catch:{ all -> 0x0097 }
    L_0x0097:
        r6 = move-exception;
        r5.close();	 Catch:{ all -> 0x009c }
        goto L_0x00a0;
    L_0x009c:
        r5 = move-exception;
        r4.addSuppressed(r5);	 Catch:{ IOException -> 0x00a1 }
    L_0x00a0:
        throw r6;	 Catch:{ IOException -> 0x00a1 }
    L_0x00a1:
        r3 = r3 + 1;
        goto L_0x0014;
    L_0x00a5:
        return r0;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.Q():java.util.ArrayList");
    }

    public static String R(int i) {
        switch (i) {
            case 1:
                return "GPRS";
            case 2:
                return "EDGE";
            case 3:
                return "UMTS";
            case 4:
                return "CDMA";
            case 5:
            case 6:
            case 12:
                return "EVDO";
            case 7:
                return "RTT";
            case 8:
                return "HSDPA";
            case 9:
                return "HSUPA";
            case 10:
                return "HSPA";
            case 11:
                return "IDEN";
            case 13:
                return "LTE";
            case 14:
                return "EHRPD";
            case 15:
                return "HSPAP";
            case 16:
                return "GSM";
            case 17:
                return "TD_SCDMA";
            case 18:
                return "IWLAN";
            case ModuleDescriptor.MODULE_VERSION /*20*/:
                return "NR";
            default:
                return DeviceInfoApp.c.getString(2131690514);
        }
    }

    /* JADX WARNING: Missing block: B:13:?, code skipped:
            r2.close();
     */
    public static java.lang.String S(java.lang.String r2) {
        /*
        r0 = new java.io.File;
        r0.<init>(r2);
        r2 = r0.exists();
        if (r2 == 0) goto L_0x0029;
    L_0x000b:
        r2 = new java.io.BufferedReader;	 Catch:{ IOException -> 0x0029 }
        r1 = new java.io.FileReader;	 Catch:{ IOException -> 0x0029 }
        r1.<init>(r0);	 Catch:{ IOException -> 0x0029 }
        r2.<init>(r1);	 Catch:{ IOException -> 0x0029 }
        r0 = r2.readLine();	 Catch:{ all -> 0x001d }
        r2.close();	 Catch:{ IOException -> 0x002b }
        goto L_0x002b;
    L_0x001d:
        r0 = move-exception;
        throw r0;	 Catch:{ all -> 0x001f }
    L_0x001f:
        r1 = move-exception;
        r2.close();	 Catch:{ all -> 0x0024 }
        goto L_0x0028;
    L_0x0024:
        r2 = move-exception;
        r0.addSuppressed(r2);	 Catch:{ IOException -> 0x0029 }
    L_0x0028:
        throw r1;	 Catch:{ IOException -> 0x0029 }
    L_0x0029:
        r0 = "";
    L_0x002b:
        return r0;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.S(java.lang.String):java.lang.String");
    }

    /* JADX WARNING: Removed duplicated region for block: B:37:0x0068 A:{SYNTHETIC, Splitter:B:37:0x0068} */
    /* JADX WARNING: Removed duplicated region for block: B:31:0x0060 A:{SYNTHETIC, Splitter:B:31:0x0060} */
    public static java.lang.String a(android.content.Context r5) {
        /*
        r0 = new java.lang.StringBuilder;
        r0.<init>();
        r1 = 0;
        r2 = java.lang.Runtime.getRuntime();	 Catch:{ Exception -> 0x0055 }
        r3 = "getenforce";
        r2 = r2.exec(r3);	 Catch:{ Exception -> 0x0055 }
        r2.waitFor();	 Catch:{ Exception -> 0x0055 }
        r3 = new java.io.BufferedReader;	 Catch:{ Exception -> 0x0055 }
        r4 = new java.io.InputStreamReader;	 Catch:{ Exception -> 0x0055 }
        r2 = r2.getInputStream();	 Catch:{ Exception -> 0x0055 }
        r4.<init>(r2);	 Catch:{ Exception -> 0x0055 }
        r3.<init>(r4);	 Catch:{ Exception -> 0x0055 }
    L_0x0021:
        r1 = r3.readLine();	 Catch:{ Exception -> 0x0051, all -> 0x004e }
        if (r1 == 0) goto L_0x002b;
    L_0x0027:
        r0.append(r1);	 Catch:{ Exception -> 0x0051, all -> 0x004e }
        goto L_0x0021;
    L_0x002b:
        r1 = c.h.a.m0.j.a;
        r3.close();	 Catch:{ IOException -> 0x0030 }
    L_0x0030:
        r0 = r0.toString();
        r1 = "Enforcing";
        r2 = r1.equals(r0);
        if (r2 == 0) goto L_0x003d;
    L_0x003c:
        return r1;
    L_0x003d:
        r1 = "Permissive";
        r0 = r1.equals(r0);
        if (r0 == 0) goto L_0x0046;
    L_0x0045:
        return r1;
    L_0x0046:
        r0 = 2131690511; // 0x7f0f040f float:1.9010068E38 double:1.053195049E-314;
        r5 = r5.getString(r0);
        return r5;
    L_0x004e:
        r5 = move-exception;
        r1 = r3;
        goto L_0x0064;
    L_0x0051:
        r1 = r3;
        goto L_0x0055;
    L_0x0053:
        r5 = move-exception;
        goto L_0x0064;
    L_0x0055:
        r0 = 2131690139; // 0x7f0f029b float:1.9009313E38 double:1.0531948653E-314;
        r5 = r5.getString(r0);	 Catch:{ all -> 0x0053 }
        r0 = c.h.a.m0.j.a;
        if (r1 == 0) goto L_0x0063;
    L_0x0060:
        r1.close();	 Catch:{ IOException -> 0x0063 }
    L_0x0063:
        return r5;
    L_0x0064:
        r0 = c.h.a.m0.j.a;
        if (r1 == 0) goto L_0x006b;
    L_0x0068:
        r1.close();	 Catch:{ IOException -> 0x006b }
    L_0x006b:
        throw r5;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.a(android.content.Context):java.lang.String");
    }

    public static String b(int i, Context context) {
        switch (i) {
            case 1:
                return context.getString(2131690286);
            case 2:
                return context.getString(2131690304);
            case 3:
                return context.getString(2131690308);
            case 4:
                return context.getString(2131690296);
            case 5:
                return context.getString(2131690301);
            case 6:
                return context.getString(2131690311);
            case 7:
                return context.getString(2131690319);
            case 8:
                return context.getString(2131690312);
            case 9:
                return context.getString(2131690295);
            case 10:
                return context.getString(2131690302);
            case 11:
                return context.getString(2131690314);
            case 12:
                return context.getString(2131690313);
            case 13:
                return context.getString(2131690289);
            case 14:
                return context.getString(2131690305);
            case 15:
                return context.getString(2131690292);
            case 16:
                return context.getString(2131690297);
            case 17:
                return context.getString(2131690315);
            case 18:
                return context.getString(2131690318);
            case ConnectionResult.SERVICE_MISSING_PERMISSION /*19*/:
                return context.getString(2131690317);
            case ModuleDescriptor.MODULE_VERSION /*20*/:
                return context.getString(2131690293);
            case 21:
                return context.getString(2131690299);
            case 22:
                return context.getString(2131690320);
            case 23:
                return context.getString(2131690322);
            case 24:
                return context.getString(2131690294);
            case 25:
                return context.getString(2131690309);
            case 26:
                return context.getString(2131690323);
            case AvailableCode.USER_IGNORE_PREVIOUS_POPUP /*27*/:
                return context.getString(2131690290);
            case 28:
                return context.getString(2131690310);
            case 29:
                return context.getString(2131690316);
            case 30:
                return context.getString(2131690306);
            case 31:
                return context.getString(2131690298);
            case 32:
                return context.getString(2131690291);
            case 33:
                return context.getString(2131690288);
            case 34:
                return context.getString(2131690303);
            case 35:
                return context.getString(2131690287);
            default:
                return context.getString(2131690514);
        }
    }

    public static String c(int i) {
        return i != 0 ? i != 1 ? i != 2 ? "" : "CDMA" : "GSM" : "None";
    }

    public static boolean d(String str) {
        try {
            if (Runtime.getRuntime().exec(str).waitFor() == 0) {
                return true;
            }
        } catch (Exception unused) {
        }
        return false;
    }

    public static List<f> e() {
        ArrayList arrayList = new ArrayList();
        SensorManager sensorManager = (SensorManager) DeviceInfoApp.c.getSystemService("sensor");
        if (sensorManager == null) {
            return Collections.emptyList();
        }
        List<Sensor> sensorList = sensorManager.getSensorList(-1);
        String string = DeviceInfoApp.c.getString(2131690514);
        ArrayList arrayList2 = new ArrayList();
        ArrayList arrayList3 = new ArrayList();
        for (Sensor sensor : sensorList) {
            String name = sensor.getName();
            StringBuilder stringBuilder = new StringBuilder();
            stringBuilder.append(DeviceInfoApp.c.getString(2131690545));
            String str = " : ";
            stringBuilder.append(str);
            stringBuilder.append(sensor.getVendor());
            String stringBuilder2 = stringBuilder.toString();
            String b = b(sensor.getType(), DeviceInfoApp.c);
            String string2 = DeviceInfoApp.c.getString(sensor.isWakeUpSensor() ? 2131690575 : 2131690129);
            StringBuilder stringBuilder3 = new StringBuilder();
            stringBuilder3.append(DeviceInfoApp.c.getString(2131690560));
            stringBuilder3.append(str);
            stringBuilder3.append(string2);
            String stringBuilder4 = stringBuilder3.toString();
            stringBuilder = new StringBuilder();
            stringBuilder.append(DeviceInfoApp.c.getString(2131690185));
            stringBuilder.append(str);
            stringBuilder.append(sensor.getPower());
            stringBuilder.append("mA");
            f fVar = new f(sensor.getType(), name, stringBuilder2, b, stringBuilder4, stringBuilder.toString());
            if (b.equals(string)) {
                arrayList3.add(fVar);
            } else {
                arrayList2.add(fVar);
            }
        }
        arrayList.addAll(arrayList2);
        arrayList.addAll(arrayList3);
        return arrayList;
    }

    public static double f() {
        String str = "com.android.internal.os.PowerProfile";
        try {
            return ((Double) Class.forName(str).getMethod("getBatteryCapacity", new Class[0]).invoke(Class.forName(str).getConstructor(new Class[]{Context.class}).newInstance(new Object[]{DeviceInfoApp.c}), new Object[0])).doubleValue();
        } catch (Throwable unused) {
            return -1.0d;
        }
    }

    public static String g(int i, Context context) {
        if (i == 7) {
            return context.getString(2131689757);
        }
        if (i == 4) {
            return context.getString(2131689778);
        }
        if (i == 2) {
            return context.getString(2131689945);
        }
        if (i == 5) {
            return context.getString(2131690161);
        }
        if (i == 3) {
            return context.getString(2131690162);
        }
        if (i == 1) {
            return context.getString(2131690514);
        }
        if (i == 6) {
            return context.getString(2131689629);
        }
        return context.getString(2131690135);
    }

    public static String h(int i, Context context) {
        if (i == 2) {
            return context.getString(2131690542);
        }
        if (i == 1) {
            return context.getString(2131689500);
        }
        return context.getString(2131689626);
    }

    public static String i(int i, Context context) {
        if (i == 2) {
            return context.getString(2131689748);
        }
        if (i == 3) {
            return context.getString(2131689799);
        }
        if (i == 5) {
            return context.getString(2131689630);
        }
        if (i == 1) {
            return context.getString(2131690514);
        }
        if (i == 4) {
            return context.getString(2131690136);
        }
        return context.getString(2131690135);
    }

    @SuppressLint({"HardwareIds"})
    public static String j(Context context) {
        String string = DeviceInfoApp.c.getString(2131690514);
        try {
            CharSequence string2;
            if (VERSION.SDK_INT >= 23) {
                string2 = Secure.getString(context.getContentResolver(), "bluetooth_address");
                if (string2 != null) {
                    string2 = string2.trim();
                }
                if (TextUtils.isEmpty(string2)) {
                    return string;
                }
            }
            BluetoothAdapter defaultAdapter = BluetoothAdapter.getDefaultAdapter();
            if (defaultAdapter == null) {
                return string;
            }
            string2 = defaultAdapter.getAddress();
            if (string2 != null) {
                string2 = string2.trim();
            }
            if (TextUtils.isEmpty(string2)) {
                return string;
            }
            return string2;
        } catch (Exception unused) {
            return string;
        }
    }

    public static String k() {
        String string = DeviceInfoApp.c.getString(2131690514);
        try {
            int i = System.getInt(DeviceInfoApp.c.getContentResolver(), "screen_brightness_mode");
            if (i == 1) {
                return DeviceInfoApp.c.getString(2131689512);
            }
            return i == 0 ? DeviceInfoApp.c.getString(2131690063) : string;
        } catch (SettingNotFoundException unused) {
            return string;
        }
    }

    /* JADX WARNING: Missing block: B:14:?, code skipped:
            r0.close();
     */
    public static java.lang.String l() {
        /*
        r0 = new java.io.File;
        r1 = "/sys/devices/system/cpu/cpu0/cpufreq/scaling_governor";
        r0.<init>(r1);
        r0 = r0.exists();
        if (r0 == 0) goto L_0x0030;
    L_0x000d:
        r0 = new java.io.BufferedReader;	 Catch:{ IOException -> 0x0030 }
        r2 = new java.io.FileReader;	 Catch:{ IOException -> 0x0030 }
        r3 = new java.io.File;	 Catch:{ IOException -> 0x0030 }
        r3.<init>(r1);	 Catch:{ IOException -> 0x0030 }
        r2.<init>(r3);	 Catch:{ IOException -> 0x0030 }
        r0.<init>(r2);	 Catch:{ IOException -> 0x0030 }
        r1 = r0.readLine();	 Catch:{ all -> 0x0024 }
        r0.close();	 Catch:{ IOException -> 0x0030 }
        return r1;
    L_0x0024:
        r1 = move-exception;
        throw r1;	 Catch:{ all -> 0x0026 }
    L_0x0026:
        r2 = move-exception;
        r0.close();	 Catch:{ all -> 0x002b }
        goto L_0x002f;
    L_0x002b:
        r0 = move-exception;
        r1.addSuppressed(r0);	 Catch:{ IOException -> 0x0030 }
    L_0x002f:
        throw r2;	 Catch:{ IOException -> 0x0030 }
    L_0x0030:
        r0 = com.liuzh.deviceinfo.DeviceInfoApp.c;
        r1 = 2131690514; // 0x7f0f0412 float:1.9010074E38 double:1.0531950505E-314;
        r0 = r0.getString(r1);
        return r0;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.l():java.lang.String");
    }

    public static String m(Key key, CameraCharacteristics cameraCharacteristics) {
        Key key2 = key;
        CameraCharacteristics cameraCharacteristics2 = cameraCharacteristics;
        ArrayList arrayList = new ArrayList();
        int i = 2;
        int i2 = 0;
        int[] iArr;
        int length;
        int i3;
        if (key2 == CameraCharacteristics.COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES) {
            iArr = (int[]) cameraCharacteristics2.get(key2);
            if (iArr == null) {
                iArr = new int[0];
            }
            length = iArr.length;
            while (i2 < length) {
                int i4 = iArr[i2];
                if (i4 == 0) {
                    arrayList.add(J(2131690141));
                } else if (i4 == 1) {
                    arrayList.add(J(2131689865));
                } else if (i4 == 2) {
                    arrayList.add(J(2131689871));
                }
                i2++;
            }
        } else if (key2 == CameraCharacteristics.CONTROL_AE_AVAILABLE_ANTIBANDING_MODES) {
            iArr = (int[]) cameraCharacteristics2.get(key2);
            if (iArr == null) {
                iArr = new int[0];
            }
            length = iArr.length;
            while (i2 < length) {
                i3 = iArr[i2];
                if (i3 == 0) {
                    arrayList.add(J(2131690141));
                } else if (i3 == 3) {
                    arrayList.add(J(2131689623));
                } else if (i3 == 1) {
                    arrayList.add("50Hz");
                } else if (i3 == 2) {
                    arrayList.add("60Hz");
                }
                i2++;
            }
        } else if (key2 == CameraCharacteristics.CONTROL_AE_AVAILABLE_MODES) {
            iArr = (int[]) cameraCharacteristics2.get(key2);
            if (iArr == null) {
                iArr = new int[0];
            }
            length = iArr.length;
            while (i2 < length) {
                i3 = iArr[i2];
                if (i3 == 0) {
                    arrayList.add(J(2131690141));
                } else if (i3 == 1) {
                    arrayList.add(J(2131690142));
                } else if (i3 == 3) {
                    arrayList.add(J(2131689841));
                } else if (i3 == 2) {
                    arrayList.add(J(2131689844));
                } else if (i3 == 4) {
                    arrayList.add(J(2131689845));
                }
                i2++;
            }
        } else if (key2 == CameraCharacteristics.CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES) {
            Range[] rangeArr = (Range[]) cameraCharacteristics2.get(key2);
            if (rangeArr != null) {
                length = rangeArr.length;
                while (i2 < length) {
                    arrayList.add(E(rangeArr[i2]));
                    i2++;
                }
            }
        } else if (key2 == CameraCharacteristics.CONTROL_AE_COMPENSATION_RANGE) {
            Range range = (Range) cameraCharacteristics2.get(key2);
            Objects.requireNonNull(range);
            arrayList.add(E(range));
        } else if (key2 == CameraCharacteristics.CONTROL_AE_COMPENSATION_STEP) {
            Rational rational = (Rational) cameraCharacteristics2.get(key2);
            Objects.requireNonNull(rational);
            arrayList.add(rational.toString());
        } else if (key2 == CameraCharacteristics.CONTROL_AF_AVAILABLE_MODES) {
            iArr = (int[]) cameraCharacteristics2.get(key2);
            if (iArr == null) {
                iArr = new int[0];
            }
            length = iArr.length;
            while (i2 < length) {
                i3 = iArr[i2];
                if (i3 == 0) {
                    arrayList.add(J(2131690141));
                } else if (i3 == 1) {
                    arrayList.add(J(2131689623));
                } else if (i3 == 5) {
                    arrayList.add(J(2131689863));
                } else if (i3 == 2) {
                    arrayList.add(J(2131689879));
                } else if (i3 == 4) {
                    arrayList.add(J(2131689858));
                } else if (i3 == 3) {
                    arrayList.add(J(2131689859));
                }
                i2++;
            }
        } else {
            int i5 = 8;
            int intValue;
            if (key2 == CameraCharacteristics.CONTROL_AVAILABLE_EFFECTS) {
                iArr = (int[]) cameraCharacteristics2.get(key2);
                if (iArr == null) {
                    iArr = new int[0];
                }
                length = iArr.length;
                while (i2 < length) {
                    int i6 = iArr[i2];
                    if (i6 == 0) {
                        arrayList.add(J(2131690141));
                    } else if (i6 == 8) {
                        arrayList.add(J(2131689843));
                    } else if (i6 == 7) {
                        arrayList.add(J(2131689849));
                    } else if (i6 == 1) {
                        arrayList.add(J(2131689882));
                    } else if (i6 == 2) {
                        arrayList.add(J(2131689885));
                    } else if (i6 == 5) {
                        arrayList.add(J(2131689891));
                    } else if (i6 == 4) {
                        arrayList.add(J(2131689898));
                    } else if (i6 == 3) {
                        arrayList.add(J(2131689902));
                    } else if (i6 == 6) {
                        arrayList.add(J(2131689911));
                    }
                    i2++;
                }
            } else if (key2 == CameraCharacteristics.CONTROL_AVAILABLE_SCENE_MODES) {
                iArr = (int[]) cameraCharacteristics2.get(key2);
                if (iArr == null) {
                    iArr = new int[0];
                }
                length = iArr.length;
                while (i2 < length) {
                    i3 = iArr[i2];
                    if (i3 == 0) {
                        arrayList.add(J(2131689798));
                    } else if (i3 == i) {
                        arrayList.add(J(2131689840));
                    } else if (i3 == 16) {
                        arrayList.add(J(2131689847));
                    } else if (i3 == 8) {
                        arrayList.add(J(2131689848));
                    } else if (i3 == 15) {
                        arrayList.add(J(2131689852));
                    } else if (i3 == 1) {
                        arrayList.add(J(2131689864));
                    } else if (i3 == 12) {
                        arrayList.add(J(2131689866));
                    } else if (i3 == 18) {
                        arrayList.add(J(2131689870));
                    } else if (i3 == 4) {
                        arrayList.add(J(2131689874));
                    } else if (i3 == 5) {
                        arrayList.add(J(2131689886));
                    } else if (i3 == 6) {
                        arrayList.add(J(2131689887));
                    } else if (i3 == 14) {
                        arrayList.add(J(2131689888));
                    } else if (i3 == 3) {
                        arrayList.add(J(2131689890));
                    } else if (i3 == 9) {
                        arrayList.add(J(2131689901));
                    } else if (i3 == 13) {
                        arrayList.add(J(2131689904));
                    } else if (i3 == 11) {
                        arrayList.add(J(2131689905));
                    } else if (i3 == 10) {
                        arrayList.add(J(2131689906));
                    } else if (i3 == 7) {
                        arrayList.add(J(2131689907));
                    } else if (i3 == 17) {
                        arrayList.add(J(2131689872));
                    }
                    i2++;
                    i = 2;
                }
            } else if (key2 == CameraCharacteristics.CONTROL_AVAILABLE_VIDEO_STABILIZATION_MODES) {
                iArr = (int[]) cameraCharacteristics2.get(key2);
                if (iArr == null) {
                    iArr = new int[0];
                }
                length = iArr.length;
                while (i2 < length) {
                    i3 = iArr[i2];
                    if (i3 == 1) {
                        arrayList.add(J(2131690142));
                    } else if (i3 == 0) {
                        arrayList.add(J(2131690141));
                    }
                    i2++;
                }
            } else if (key2 == CameraCharacteristics.CONTROL_AWB_AVAILABLE_MODES) {
                iArr = (int[]) cameraCharacteristics2.get(key2);
                if (iArr == null) {
                    iArr = new int[0];
                }
                length = iArr.length;
                while (i2 < length) {
                    i3 = iArr[i2];
                    if (i3 == 0) {
                        arrayList.add(J(2131690141));
                    } else if (i3 == 1) {
                        arrayList.add(J(2131689623));
                    } else if (i3 == 6) {
                        arrayList.add(J(2131689854));
                    } else if (i3 == 5) {
                        arrayList.add(J(2131689861));
                    } else if (i3 == 3) {
                        arrayList.add(J(2131689867));
                    } else if (i3 == 2) {
                        arrayList.add(J(2131689873));
                    } else if (i3 == 8) {
                        arrayList.add(J(2131689899));
                    } else if (i3 == 7) {
                        arrayList.add(J(2131689908));
                    } else if (i3 == 4) {
                        arrayList.add(J(2131689910));
                    }
                    i2++;
                }
            } else if (key2 == CameraCharacteristics.CONTROL_MAX_REGIONS_AE) {
                arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
            } else if (key2 == CameraCharacteristics.CONTROL_MAX_REGIONS_AF) {
                arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
            } else if (key2 == CameraCharacteristics.CONTROL_MAX_REGIONS_AWB) {
                arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
            } else if (key2 == CameraCharacteristics.EDGE_AVAILABLE_EDGE_MODES) {
                iArr = (int[]) cameraCharacteristics2.get(key2);
                if (iArr == null) {
                    iArr = new int[0];
                }
                length = iArr.length;
                while (i2 < length) {
                    i3 = iArr[i2];
                    if (i3 == 0) {
                        arrayList.add(J(2131690141));
                    } else if (i3 == 1) {
                        arrayList.add(J(2131689865));
                    } else if (i3 == 2) {
                        arrayList.add(J(2131689871));
                    } else if (i3 == 3) {
                        arrayList.add(J(2131689913));
                    }
                    i2++;
                }
            } else if (key2 == CameraCharacteristics.FLASH_INFO_AVAILABLE) {
                arrayList.add(J(((Boolean) cameraCharacteristics2.get(key2)).booleanValue() ? 2131690575 : 2131690129));
            } else if (key2 == CameraCharacteristics.HOT_PIXEL_AVAILABLE_HOT_PIXEL_MODES) {
                iArr = (int[]) cameraCharacteristics2.get(key2);
                if (iArr == null) {
                    iArr = new int[0];
                }
                length = iArr.length;
                while (i2 < length) {
                    i3 = iArr[i2];
                    if (i3 == 0) {
                        arrayList.add(J(2131690141));
                    } else if (i3 == 1) {
                        arrayList.add(J(2131689865));
                    } else if (i3 == 2) {
                        arrayList.add(J(2131689871));
                    }
                    i2++;
                }
            } else if (key2 == CameraCharacteristics.INFO_SUPPORTED_HARDWARE_LEVEL) {
                intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                if (intValue == 3) {
                    arrayList.add(J(2131689876));
                } else if (intValue == 4) {
                    arrayList.add(J(2131689834));
                } else if (intValue == 1) {
                    arrayList.add(J(2131689869));
                } else if (intValue == 2) {
                    arrayList.add(J(2131689875));
                } else if (intValue == 0) {
                    arrayList.add(J(2131689877));
                }
            } else {
                String str = " x ";
                Size[] sizeArr;
                Size size;
                StringBuilder stringBuilder;
                float[] fArr;
                StringBuilder stringBuilder2;
                if (key2 == CameraCharacteristics.JPEG_AVAILABLE_THUMBNAIL_SIZES) {
                    sizeArr = (Size[]) cameraCharacteristics2.get(key2);
                    if (sizeArr == null) {
                        sizeArr = new Size[0];
                    }
                    length = sizeArr.length;
                    while (i2 < length) {
                        size = sizeArr[i2];
                        stringBuilder = new StringBuilder();
                        stringBuilder.append(size.getWidth());
                        stringBuilder.append(str);
                        stringBuilder.append(size.getHeight());
                        arrayList.add(stringBuilder.toString());
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.LENS_FACING) {
                    intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                    if (intValue == 1) {
                        arrayList.add(J(2131689683));
                    } else if (intValue == 2) {
                        arrayList.add(J(2131689834));
                    } else if (intValue == 0) {
                        arrayList.add(J(2131689698));
                    } else {
                        arrayList.add(J(2131690514));
                    }
                } else if (key2 == CameraCharacteristics.LENS_INFO_AVAILABLE_APERTURES) {
                    fArr = (float[]) cameraCharacteristics2.get(key2);
                    if (fArr == null) {
                        fArr = new float[0];
                    }
                    length = fArr.length;
                    while (i2 < length) {
                        arrayList.add(String.valueOf(fArr[i2]));
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.LENS_INFO_AVAILABLE_FILTER_DENSITIES) {
                    fArr = (float[]) cameraCharacteristics2.get(key2);
                    if (fArr == null) {
                        fArr = new float[0];
                    }
                    length = fArr.length;
                    while (i2 < length) {
                        arrayList.add(String.valueOf(fArr[i2]));
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.LENS_INFO_AVAILABLE_FOCAL_LENGTHS) {
                    fArr = (float[]) cameraCharacteristics2.get(key2);
                    if (fArr == null) {
                        fArr = new float[0];
                    }
                    length = fArr.length;
                    while (i2 < length) {
                        float f = fArr[i2];
                        stringBuilder = new StringBuilder();
                        stringBuilder.append(f);
                        stringBuilder.append("mm");
                        arrayList.add(stringBuilder.toString());
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.LENS_INFO_AVAILABLE_OPTICAL_STABILIZATION) {
                    iArr = (int[]) cameraCharacteristics2.get(key2);
                    if (iArr == null) {
                        iArr = new int[0];
                    }
                    length = iArr.length;
                    while (i2 < length) {
                        i3 = iArr[i2];
                        if (i3 == 0) {
                            arrayList.add(J(2131690141));
                        } else if (i3 == 1) {
                            arrayList.add(J(2131690142));
                            i2++;
                        }
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.LENS_INFO_FOCUS_DISTANCE_CALIBRATION) {
                    intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                    if (intValue == 1) {
                        arrayList.add(J(2131689842));
                    } else if (intValue == 2) {
                        arrayList.add(J(2131689851));
                    } else if (intValue == 0) {
                        arrayList.add(J(2131689909));
                    }
                } else if (key2 == CameraCharacteristics.LENS_INFO_HYPERFOCAL_DISTANCE) {
                    arrayList.add(String.valueOf(((Float) cameraCharacteristics2.get(key2)).floatValue()));
                } else if (key2 == CameraCharacteristics.LENS_INFO_MINIMUM_FOCUS_DISTANCE) {
                    arrayList.add(String.valueOf(((Float) cameraCharacteristics2.get(key2)).floatValue()));
                } else if (key2 == CameraCharacteristics.REQUEST_AVAILABLE_CAPABILITIES) {
                    iArr = (int[]) cameraCharacteristics2.get(key2);
                    if (iArr == null) {
                        iArr = new int[0];
                    }
                    length = iArr.length;
                    while (i2 < length) {
                        i3 = iArr[i2];
                        if (i3 == 0) {
                            arrayList.add(J(2131689846));
                        } else if (i3 == 6) {
                            arrayList.add(J(2131689850));
                        } else if (i3 == 9) {
                            arrayList.add(J(2131689857));
                        } else if (i3 == i5) {
                            arrayList.add(J(2131689862));
                        } else if (i3 == 11) {
                            arrayList.add(J(2131689878));
                        } else if (i3 == 2) {
                            arrayList.add(J(2131689880));
                        } else if (i3 == 1) {
                            arrayList.add(J(2131689881));
                        } else if (i3 == 12) {
                            arrayList.add(J(2131689883));
                        } else {
                            if (i3 == 10) {
                                arrayList.add(J(2131689884));
                            } else if (i3 == 4) {
                                arrayList.add(J(2131689892));
                            } else if (i3 == 3) {
                                arrayList.add(J(2131689893));
                            } else if (i3 == 5) {
                                arrayList.add(J(2131689894));
                            } else {
                                if (i3 == 7) {
                                    arrayList.add(J(2131689912));
                                }
                                i2++;
                                i5 = 8;
                            }
                            i2++;
                            i5 = 8;
                        }
                        i2++;
                        i5 = 8;
                    }
                } else if (key2 == CameraCharacteristics.REQUEST_MAX_NUM_OUTPUT_PROC) {
                    arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
                } else if (key2 == CameraCharacteristics.REQUEST_MAX_NUM_OUTPUT_PROC_STALLING) {
                    arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
                } else if (key2 == CameraCharacteristics.REQUEST_MAX_NUM_OUTPUT_RAW) {
                    arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
                } else if (key2 == CameraCharacteristics.REQUEST_PARTIAL_RESULT_COUNT) {
                    arrayList.add(String.valueOf(((Integer) cameraCharacteristics2.get(key2)).intValue()));
                } else if (key2 == CameraCharacteristics.SCALER_AVAILABLE_MAX_DIGITAL_ZOOM) {
                    arrayList.add(String.valueOf(((Float) cameraCharacteristics2.get(key2)).floatValue()));
                } else if (key2 == CameraCharacteristics.SCALER_STREAM_CONFIGURATION_MAP) {
                    StreamConfigurationMap streamConfigurationMap = (StreamConfigurationMap) cameraCharacteristics2.get(key2);
                    Objects.requireNonNull(streamConfigurationMap);
                    sizeArr = streamConfigurationMap.getOutputSizes(256);
                    length = sizeArr.length;
                    while (i2 < length) {
                        size = sizeArr[i2];
                        stringBuilder = new StringBuilder();
                        stringBuilder.append(A(size, 2));
                        stringBuilder.append(" - ");
                        stringBuilder.append(size.getWidth());
                        stringBuilder.append(str);
                        stringBuilder.append(size.getHeight());
                        arrayList.add(stringBuilder.toString());
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.SCALER_CROPPING_TYPE) {
                    intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                    if (intValue == 0) {
                        arrayList.add(J(2131689853));
                    } else if (intValue == 1) {
                        arrayList.add(J(2131689868));
                    }
                } else if (key2 == CameraCharacteristics.SENSOR_AVAILABLE_TEST_PATTERN_MODES) {
                    iArr = (int[]) cameraCharacteristics2.get(key2);
                    if (iArr == null) {
                        iArr = new int[0];
                    }
                    length = iArr.length;
                    while (i2 < length) {
                        i5 = iArr[i2];
                        if (i5 == 0) {
                            arrayList.add(J(2131690141));
                        } else if (i5 == 2) {
                            arrayList.add(J(2131689855));
                        } else if (i5 == 3) {
                            arrayList.add(J(2131689856));
                        } else if (i5 == 256) {
                            arrayList.add(J(2131689860));
                        } else if (i5 == 4) {
                            arrayList.add(J(2131689889));
                        } else if (i5 == 1) {
                            arrayList.add(J(2131689903));
                        }
                        i2++;
                    }
                } else if (key2 == CameraCharacteristics.SENSOR_INFO_COLOR_FILTER_ARRANGEMENT) {
                    intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                    if (intValue == 3) {
                        arrayList.add("BGGR");
                    } else if (intValue == 2) {
                        arrayList.add("GBRG");
                    } else if (intValue == 1) {
                        arrayList.add("GRGB");
                    } else if (intValue == 4) {
                        arrayList.add("RGB");
                    } else if (intValue == 0) {
                        arrayList.add("RGGB");
                    } else if (intValue == 5) {
                        arrayList.add("MONO");
                    } else if (intValue == 6) {
                        arrayList.add("NIR");
                    }
                } else if (key2 == CameraCharacteristics.SENSOR_INFO_TIMESTAMP_SOURCE) {
                    intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                    if (intValue == 1) {
                        arrayList.add(J(2131689895));
                    } else if (intValue == 0) {
                        arrayList.add(J(2131690514));
                    }
                } else if (key2 == CameraCharacteristics.SENSOR_INFO_PHYSICAL_SIZE) {
                    SizeF sizeF = (SizeF) cameraCharacteristics2.get(key2);
                    stringBuilder2 = new StringBuilder();
                    Locale locale = Locale.US;
                    Object[] objArr = new Object[1];
                    Objects.requireNonNull(sizeF);
                    objArr[0] = Float.valueOf(sizeF.getWidth());
                    String str2 = "%.2f";
                    stringBuilder2.append(String.format(locale, str2, objArr));
                    stringBuilder2.append(str);
                    stringBuilder2.append(String.format(locale, str2, new Object[]{Float.valueOf(sizeF.getHeight())}));
                    arrayList.add(stringBuilder2.toString());
                } else if (key2 == CameraCharacteristics.SENSOR_INFO_PIXEL_ARRAY_SIZE) {
                    Size size2 = (Size) cameraCharacteristics2.get(key2);
                    stringBuilder2 = new StringBuilder();
                    Objects.requireNonNull(size2);
                    stringBuilder2.append(size2.getWidth());
                    stringBuilder2.append(str);
                    stringBuilder2.append(size2.getHeight());
                    arrayList.add(stringBuilder2.toString());
                } else if (key2 == CameraCharacteristics.SENSOR_ORIENTATION) {
                    intValue = ((Integer) cameraCharacteristics2.get(key2)).intValue();
                    stringBuilder2 = new StringBuilder();
                    stringBuilder2.append(intValue);
                    stringBuilder2.append(" deg");
                    arrayList.add(stringBuilder2.toString());
                } else if (key2 == CameraCharacteristics.STATISTICS_INFO_AVAILABLE_FACE_DETECT_MODES) {
                    iArr = (int[]) cameraCharacteristics2.get(key2);
                    if (iArr == null) {
                        iArr = new int[0];
                    }
                    length = iArr.length;
                    while (i2 < length) {
                        i3 = iArr[i2];
                        if (i3 == 0) {
                            arrayList.add(J(2131690141));
                        } else if (i3 == 2) {
                            arrayList.add(J(2131689869));
                        } else if (i3 == 1) {
                            arrayList.add(J(2131689900));
                        }
                        i2++;
                    }
                }
            }
        }
        String substring = arrayList.toString().substring(1, arrayList.toString().length() - 1);
        if (key2 == CameraCharacteristics.SCALER_STREAM_CONFIGURATION_MAP || key2 == CameraCharacteristics.JPEG_AVAILABLE_THUMBNAIL_SIZES) {
            return substring.replace(", ", "\n");
        }
        return substring;
    }

    public static String n(Size[] sizeArr) {
        int i = 0;
        String A = A(sizeArr[0], 1);
        int width = sizeArr[0].getWidth() * sizeArr[0].getHeight();
        int length = sizeArr.length;
        while (i < length) {
            Size size = sizeArr[i];
            int width2 = size.getWidth() * size.getHeight();
            if (width2 > width) {
                A = A(size, 1);
                width = width2;
            }
            i++;
        }
        return A;
    }

    public static String o(Size[] sizeArr) {
        Size size = sizeArr[0];
        String str = "x";
        StringBuilder stringBuilder;
        if (sizeArr.length > 1) {
            Size size2 = sizeArr[sizeArr.length - 1];
            if (size.getWidth() > size2.getWidth()) {
                stringBuilder = new StringBuilder();
                stringBuilder.append(size.getWidth());
                stringBuilder.append(str);
                stringBuilder.append(size.getHeight());
                return stringBuilder.toString();
            }
            StringBuilder stringBuilder2 = new StringBuilder();
            stringBuilder2.append(size2.getWidth());
            stringBuilder2.append(str);
            stringBuilder2.append(size2.getHeight());
            return stringBuilder2.toString();
        }
        stringBuilder = new StringBuilder();
        stringBuilder.append(size.getWidth());
        stringBuilder.append(str);
        stringBuilder.append(size.getHeight());
        return stringBuilder.toString();
    }

    /* JADX WARNING: Missing block: B:20:?, code skipped:
            r7.close();
     */
    /* JADX WARNING: Missing block: B:21:0x007f, code skipped:
            r7 = move-exception;
     */
    /* JADX WARNING: Missing block: B:23:?, code skipped:
            r8.addSuppressed(r7);
     */
    /* JADX WARNING: Missing block: B:30:?, code skipped:
            r6.close();
     */
    public static float[] p() {
        /*
        r0 = "r";
        r1 = "/sys/devices/system/cpu/cpu";
        r2 = 2;
        r2 = new float[r2];
        r3 = java.lang.Runtime.getRuntime();
        r3 = r3.availableProcessors();
        r4 = 0;
        r5 = 0;
    L_0x0011:
        if (r5 >= r3) goto L_0x0094;
    L_0x0013:
        r6 = new java.io.RandomAccessFile;	 Catch:{ IOException -> 0x0090 }
        r7 = new java.lang.StringBuilder;	 Catch:{ IOException -> 0x0090 }
        r7.<init>();	 Catch:{ IOException -> 0x0090 }
        r7.append(r1);	 Catch:{ IOException -> 0x0090 }
        r7.append(r5);	 Catch:{ IOException -> 0x0090 }
        r8 = "/cpufreq/cpuinfo_max_freq";
        r7.append(r8);	 Catch:{ IOException -> 0x0090 }
        r7 = r7.toString();	 Catch:{ IOException -> 0x0090 }
        r6.<init>(r7, r0);	 Catch:{ IOException -> 0x0090 }
        r7 = new java.io.RandomAccessFile;	 Catch:{ all -> 0x0084 }
        r8 = new java.lang.StringBuilder;	 Catch:{ all -> 0x0084 }
        r8.<init>();	 Catch:{ all -> 0x0084 }
        r8.append(r1);	 Catch:{ all -> 0x0084 }
        r8.append(r5);	 Catch:{ all -> 0x0084 }
        r9 = "/cpufreq/cpuinfo_min_freq";
        r8.append(r9);	 Catch:{ all -> 0x0084 }
        r8 = r8.toString();	 Catch:{ all -> 0x0084 }
        r7.<init>(r8, r0);	 Catch:{ all -> 0x0084 }
        r8 = r6.readLine();	 Catch:{ all -> 0x0078 }
        r9 = r7.readLine();	 Catch:{ all -> 0x0078 }
        r8 = java.lang.Float.parseFloat(r8);	 Catch:{ all -> 0x0078 }
        r10 = 1148846080; // 0x447a0000 float:1000.0 double:5.676053805E-315;
        r8 = r8 / r10;
        r9 = java.lang.Float.parseFloat(r9);	 Catch:{ all -> 0x0078 }
        r9 = r9 / r10;
        r10 = 1;
        if (r5 != 0) goto L_0x0061;
    L_0x005c:
        r2[r4] = r9;	 Catch:{ all -> 0x0078 }
        r2[r10] = r8;	 Catch:{ all -> 0x0078 }
        goto L_0x0071;
    L_0x0061:
        r11 = r2[r4];	 Catch:{ all -> 0x0078 }
        r9 = java.lang.Math.min(r11, r9);	 Catch:{ all -> 0x0078 }
        r2[r4] = r9;	 Catch:{ all -> 0x0078 }
        r9 = r2[r10];	 Catch:{ all -> 0x0078 }
        r8 = java.lang.Math.max(r9, r8);	 Catch:{ all -> 0x0078 }
        r2[r10] = r8;	 Catch:{ all -> 0x0078 }
    L_0x0071:
        r7.close();	 Catch:{ all -> 0x0084 }
        r6.close();	 Catch:{ IOException -> 0x0090 }
        goto L_0x0090;
    L_0x0078:
        r8 = move-exception;
        throw r8;	 Catch:{ all -> 0x007a }
    L_0x007a:
        r9 = move-exception;
        r7.close();	 Catch:{ all -> 0x007f }
        goto L_0x0083;
    L_0x007f:
        r7 = move-exception;
        r8.addSuppressed(r7);	 Catch:{ all -> 0x0084 }
    L_0x0083:
        throw r9;	 Catch:{ all -> 0x0084 }
    L_0x0084:
        r7 = move-exception;
        throw r7;	 Catch:{ all -> 0x0086 }
    L_0x0086:
        r8 = move-exception;
        r6.close();	 Catch:{ all -> 0x008b }
        goto L_0x008f;
    L_0x008b:
        r6 = move-exception;
        r7.addSuppressed(r6);	 Catch:{ IOException -> 0x0090 }
    L_0x008f:
        throw r8;	 Catch:{ IOException -> 0x0090 }
    L_0x0090:
        r5 = r5 + 1;
        goto L_0x0011;
    L_0x0094:
        return r2;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.p():float[]");
    }

    /* JADX WARNING: Missing block: B:11:?, code skipped:
            r4.close();
     */
    /* JADX WARNING: Missing block: B:17:?, code skipped:
            r4.close();
     */
    public static java.lang.String q() {
        /*
        r0 = "ndeviceinfo";
        r1 = new java.io.File;
        r2 = "/proc/cpuinfo";
        r1.<init>(r2);
        r2 = r1.exists();
        r3 = "";
        if (r2 != 0) goto L_0x0012;
    L_0x0011:
        goto L_0x0078;
    L_0x0012:
        r2 = new java.lang.StringBuilder;
        r2.<init>();
        r4 = new java.io.BufferedReader;	 Catch:{ IOException -> 0x004a }
        r5 = new java.io.FileReader;	 Catch:{ IOException -> 0x004a }
        r5.<init>(r1);	 Catch:{ IOException -> 0x004a }
        r4.<init>(r5);	 Catch:{ IOException -> 0x004a }
    L_0x0021:
        r1 = r4.readLine();	 Catch:{ all -> 0x003e }
        if (r1 == 0) goto L_0x003a;
    L_0x0027:
        r5 = new java.lang.StringBuilder;	 Catch:{ all -> 0x003e }
        r5.<init>();	 Catch:{ all -> 0x003e }
        r5.append(r1);	 Catch:{ all -> 0x003e }
        r5.append(r0);	 Catch:{ all -> 0x003e }
        r1 = r5.toString();	 Catch:{ all -> 0x003e }
        r2.append(r1);	 Catch:{ all -> 0x003e }
        goto L_0x0021;
    L_0x003a:
        r4.close();	 Catch:{ IOException -> 0x004a }
        goto L_0x004a;
    L_0x003e:
        r1 = move-exception;
        throw r1;	 Catch:{ all -> 0x0040 }
    L_0x0040:
        r5 = move-exception;
        r4.close();	 Catch:{ all -> 0x0045 }
        goto L_0x0049;
    L_0x0045:
        r4 = move-exception;
        r1.addSuppressed(r4);	 Catch:{ IOException -> 0x004a }
    L_0x0049:
        throw r5;	 Catch:{ IOException -> 0x004a }
    L_0x004a:
        r1 = r2.toString();
        r2 = ":";
        r1 = r1.split(r2);
        r2 = 0;
    L_0x0055:
        r4 = r1.length;
        if (r2 >= r4) goto L_0x0078;
    L_0x0058:
        r4 = r1[r2];
        r4 = r4.toLowerCase();
        r5 = "hardware";
        r4 = r4.contains(r5);
        if (r4 == 0) goto L_0x0075;
    L_0x0066:
        r3 = 1;
        r2 = r2 + r3;
        r4 = r1[r2];
        r0 = r4.indexOf(r0);
        r1 = r1[r2];
        r3 = r1.substring(r3, r0);
        goto L_0x0078;
    L_0x0075:
        r2 = r2 + 1;
        goto L_0x0055;
    L_0x0078:
        r0 = android.text.TextUtils.isEmpty(r3);
        if (r0 == 0) goto L_0x0080;
    L_0x007e:
        r3 = android.os.Build.HARDWARE;
    L_0x0080:
        return r3;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.q():java.lang.String");
    }

    /* JADX WARNING: Missing block: B:22:?, code skipped:
            r0.close();
     */
    public static java.lang.String r(java.lang.String r4) {
        /*
        r0 = "on ";
        r1 = " type";
        r4 = c.b.a.a.a.E(r0, r4, r1);
        r0 = new java.io.BufferedReader;	 Catch:{ Exception -> 0x005b }
        r1 = new java.io.InputStreamReader;	 Catch:{ Exception -> 0x005b }
        r2 = java.lang.Runtime.getRuntime();	 Catch:{ Exception -> 0x005b }
        r3 = "mount";
        r2 = r2.exec(r3);	 Catch:{ Exception -> 0x005b }
        r2 = r2.getInputStream();	 Catch:{ Exception -> 0x005b }
        r1.<init>(r2);	 Catch:{ Exception -> 0x005b }
        r0.<init>(r1);	 Catch:{ Exception -> 0x005b }
    L_0x0020:
        r1 = r0.readLine();	 Catch:{ all -> 0x004f }
        if (r1 == 0) goto L_0x004b;
    L_0x0026:
        r2 = r1.contains(r4);	 Catch:{ all -> 0x004f }
        if (r2 == 0) goto L_0x0020;
    L_0x002c:
        r4 = r1.split(r4);	 Catch:{ all -> 0x004f }
        r1 = r4.length;	 Catch:{ all -> 0x004f }
        r2 = 2;
        if (r1 != r2) goto L_0x004b;
    L_0x0034:
        r1 = 1;
        r4 = r4[r1];	 Catch:{ all -> 0x004f }
        r4 = r4.trim();	 Catch:{ all -> 0x004f }
        r3 = " ";
        r4 = r4.split(r3, r2);	 Catch:{ all -> 0x004f }
        r2 = r4.length;	 Catch:{ all -> 0x004f }
        if (r2 < r1) goto L_0x004b;
    L_0x0044:
        r1 = 0;
        r4 = r4[r1];	 Catch:{ all -> 0x004f }
        r0.close();	 Catch:{ Exception -> 0x005b }
        return r4;
    L_0x004b:
        r0.close();	 Catch:{ Exception -> 0x005b }
        goto L_0x005b;
    L_0x004f:
        r4 = move-exception;
        throw r4;	 Catch:{ all -> 0x0051 }
    L_0x0051:
        r1 = move-exception;
        r0.close();	 Catch:{ all -> 0x0056 }
        goto L_0x005a;
    L_0x0056:
        r0 = move-exception;
        r4.addSuppressed(r0);	 Catch:{ Exception -> 0x005b }
    L_0x005a:
        throw r1;	 Catch:{ Exception -> 0x005b }
    L_0x005b:
        r4 = "";
        return r4;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.h.a.m0.k.r(java.lang.String):java.lang.String");
    }

    public static String s(String str) {
        if (TextUtils.isEmpty(str)) {
            return DeviceInfoApp.c.getString(2131690514);
        }
        try {
            double d;
            double d2;
            int parseInt = Integer.parseInt(str.trim());
            if (parseInt >= VersionCodes.CUR_DEVELOPMENT) {
                d = (double) parseInt;
                d2 = 1000.0d;
            } else if (parseInt >= 1000) {
                d = (double) parseInt;
                d2 = 100.0d;
            } else {
                d = (double) parseInt;
                if (parseInt > 100) {
                    d /= 10.0d;
                }
                d = Math.abs(d);
                if (d > 10.0d || d >= 80.0d) {
                    return null;
                }
                StringBuilder stringBuilder = new StringBuilder();
                stringBuilder.append(a.format(d));
                stringBuilder.append(" ℃");
                return stringBuilder.toString();
            }
            d /= d2;
            d = Math.abs(d);
            if (d > 10.0d) {
            }
            return null;
        } catch (NumberFormatException unused) {
            return DeviceInfoApp.c.getString(2131690514);
        }
    }

    public static String t(Context context) {
        String str = "";
        try {
            Cursor query = context.getContentResolver().query(Uri.parse("content://com.google.android.gsf.gservices"), null, null, new String[]{"android_id"}, null);
            if (query == null) {
                return str;
            }
            if (query.moveToFirst()) {
                if (query.getColumnCount() >= 2) {
                    String toHexString = Long.toHexString(Long.parseLong(query.getString(1)));
                    query.close();
                    return toHexString.toUpperCase().trim();
                }
            }
            query.close();
            return str;
        } catch (Exception unused) {
        }
    }

    public static String u() {
        try {
            String property = System.getProperty("java.runtime.name");
            String property2 = System.getProperty("java.runtime.version");
            if (TextUtils.isEmpty(property)) {
                return property2;
            }
            if (TextUtils.isEmpty(property2)) {
                return DeviceInfoApp.c.getString(2131690514);
            }
            StringBuilder stringBuilder = new StringBuilder();
            stringBuilder.append(property);
            stringBuilder.append(" ");
            stringBuilder.append(property2);
            return stringBuilder.toString();
        } catch (Exception unused) {
            return DeviceInfoApp.c.getString(2131690514);
        }
    }

    public static String v() {
        try {
            CharSequence property = System.getProperty("java.vm.name");
            String property2 = System.getProperty("java.vm.version");
            if ("DALVIK".equalsIgnoreCase(property) && property2 != null && property2.startsWith("2.")) {
                property = "ART";
            }
            if (TextUtils.isEmpty(property)) {
                return property2;
            }
            if (TextUtils.isEmpty(property2)) {
                return DeviceInfoApp.c.getString(2131690514);
            }
            StringBuilder stringBuilder = new StringBuilder();
            stringBuilder.append(property);
            stringBuilder.append(" ");
            stringBuilder.append(property2);
            return stringBuilder.toString();
        } catch (Exception unused) {
            return DeviceInfoApp.c.getString(2131690514);
        }
    }

    public static String w() {
        return Formatter.formatFileSize(DeviceInfoApp.c, Runtime.getRuntime().maxMemory());
    }

    public static String x() {
        try {
            String property = System.getProperty("os.arch");
            if (property == null) {
                return DeviceInfoApp.c.getString(2131690514);
            }
            return property;
        } catch (Exception unused) {
            return DeviceInfoApp.c.getString(2131690514);
        }
    }

    public static String y(String str, Context context) {
        str.hashCode();
        Object obj = -1;
        switch (str.hashCode()) {
            case -2144194295:
                if (str.equals("android.control.availableEffects")) {
                    obj = null;
                    break;
                }
                break;
            case -2085399949:
                if (str.equals("android.control.availableVideoStabilizationModes")) {
                    obj = 1;
                    break;
                }
                break;
            case -2067237587:
                if (str.equals("android.scaler.streamConfigurationMap")) {
                    obj = 2;
                    break;
                }
                break;
            case -2050570373:
                if (str.equals("android.sensor.orientation")) {
                    obj = 3;
                    break;
                }
                break;
            case -2012429597:
                if (str.equals("android.control.awbAvailableModes")) {
                    obj = 4;
                    break;
                }
                break;
            case -1781194999:
                if (str.equals("android.sensor.info.activeArraySize")) {
                    obj = 5;
                    break;
                }
                break;
            case -1717981697:
                if (str.equals("android.sensor.info.pixelArraySize")) {
                    obj = 6;
                    break;
                }
                break;
            case -1682418278:
                if (str.equals("android.control.aeCompensationStep")) {
                    obj = 7;
                    break;
                }
                break;
            case -1628195331:
                if (str.equals("android.lens.info.hyperfocalDistance")) {
                    obj = 8;
                    break;
                }
                break;
            case -1505304580:
                if (str.equals("android.edge.availableEdgeModes")) {
                    obj = 9;
                    break;
                }
                break;
            case -1406673711:
                if (str.equals("android.tonemap.maxCurvePoints")) {
                    obj = 10;
                    break;
                }
                break;
            case -1400206546:
                if (str.equals("android.lens.info.minimumFocusDistance")) {
                    obj = 11;
                    break;
                }
                break;
            case -1395379948:
                if (str.equals("android.lens.info.availableFilterDensities")) {
                    obj = 12;
                    break;
                }
                break;
            case -1134670277:
                if (str.equals("android.control.aeAvailableModes")) {
                    obj = 13;
                    break;
                }
                break;
            case -1079191798:
                if (str.equals("android.shading.availableModes")) {
                    obj = 14;
                    break;
                }
                break;
            case -1055777788:
                if (str.equals("android.hotPixel.availableHotPixelModes")) {
                    obj = 15;
                    break;
                }
                break;
            case -759619831:
                if (str.equals("android.sensor.info.sensitivityRange")) {
                    obj = 16;
                    break;
                }
                break;
            case -616840145:
                if (str.equals("android.control.aeCompensationRange")) {
                    obj = 17;
                    break;
                }
                break;
            case -581611898:
                if (str.equals("android.sensor.availableTestPatternModes")) {
                    obj = 18;
                    break;
                }
                break;
            case -285079305:
                if (str.equals("android.control.availableModes")) {
                    obj = 19;
                    break;
                }
                break;
            case -196644446:
                if (str.equals("android.statistics.info.availableHotPixelMapModes")) {
                    obj = 20;
                    break;
                }
                break;
            case -176083809:
                if (str.equals("android.request.pipelineMaxDepth")) {
                    obj = 21;
                    break;
                }
                break;
            case -109549983:
                if (str.equals("android.lens.info.availableOpticalStabilization")) {
                    obj = 22;
                    break;
                }
                break;
            case -84249950:
                if (str.equals("android.colorCorrection.availableAberrationModes")) {
                    obj = 23;
                    break;
                }
                break;
            case -82264433:
                if (str.equals("android.control.maxRegionsAe")) {
                    obj = 24;
                    break;
                }
                break;
            case -82264432:
                if (str.equals("android.control.maxRegionsAf")) {
                    obj = 25;
                    break;
                }
                break;
            case 24681830:
                if (str.equals("android.flash.info.available")) {
                    obj = 26;
                    break;
                }
                break;
            case 113141401:
                if (str.equals("android.request.maxNumOutputProcStalling")) {
                    obj = 27;
                    break;
                }
                break;
            case 137473480:
                if (str.equals("android.jpeg.availableThumbnailSizes")) {
                    obj = 28;
                    break;
                }
                break;
            case 250439070:
                if (str.equals("android.sensor.info.preCorrectionActiveArraySize")) {
                    obj = 29;
                    break;
                }
                break;
            case 334058816:
                if (str.equals("android.sensor.maxAnalogSensitivity")) {
                    obj = 30;
                    break;
                }
                break;
            case 355844091:
                if (str.equals("android.statistics.info.availableFaceDetectModes")) {
                    obj = 31;
                    break;
                }
                break;
            case 372881532:
                if (str.equals("android.control.afAvailableModes")) {
                    obj = 32;
                    break;
                }
                break;
            case 435931913:
                if (str.equals("android.request.maxNumInputStreams")) {
                    obj = 33;
                    break;
                }
                break;
            case 588233242:
                if (str.equals("android.control.aeAvailableAntibandingModes")) {
                    obj = 34;
                    break;
                }
                break;
            case 655311930:
                if (str.equals("android.sensor.info.colorFilterArrangement")) {
                    obj = 35;
                    break;
                }
                break;
            case 706509487:
                if (str.equals("android.info.supportedHardwareLevel")) {
                    obj = 36;
                    break;
                }
                break;
            case 733744130:
                if (str.equals("android.statistics.info.maxFaceCount")) {
                    obj = 37;
                    break;
                }
                break;
            case 733983498:
                if (str.equals("android.control.aeLockAvailable")) {
                    obj = 38;
                    break;
                }
                break;
            case 806414371:
                if (str.equals("android.sensor.info.physicalSize")) {
                    obj = 39;
                    break;
                }
                break;
            case 877601319:
                if (str.equals("android.request.maxNumOutputRaw")) {
                    obj = 40;
                    break;
                }
                break;
            case 882585206:
                if (str.equals("android.sensor.blackLevelPattern")) {
                    obj = 41;
                    break;
                }
                break;
            case 1063307299:
                if (str.equals("android.scaler.croppingType")) {
                    obj = 42;
                    break;
                }
                break;
            case 1121375170:
                if (str.equals("android.lens.info.availableFocalLengths")) {
                    obj = 43;
                    break;
                }
                break;
            case 1183317953:
                if (str.equals("android.request.availableCapabilities")) {
                    obj = 44;
                    break;
                }
                break;
            case 1186535883:
                if (str.equals("android.lens.facing")) {
                    obj = 45;
                    break;
                }
                break;
            case 1345574281:
                if (str.equals("android.lens.info.availableApertures")) {
                    obj = 46;
                    break;
                }
                break;
            case 1345672452:
                if (str.equals("android.noiseReduction.availableNoiseReductionModes")) {
                    obj = 47;
                    break;
                }
                break;
            case 1435793719:
                if (str.equals("android.request.maxNumOutputProc")) {
                    obj = 48;
                    break;
                }
                break;
            case 1536952674:
                if (str.equals("android.control.awbLockAvailable")) {
                    obj = 49;
                    break;
                }
                break;
            case 1552102123:
                if (str.equals("android.statistics.info.availableLensShadingMapModes")) {
                    obj = 50;
                    break;
                }
                break;
            case 1554977615:
                if (str.equals("android.request.partialResultCount")) {
                    obj = 51;
                    break;
                }
                break;
            case 1587983432:
                if (str.equals("android.sensor.info.maxFrameDuration")) {
                    obj = 52;
                    break;
                }
                break;
            case 1624387756:
                if (str.equals("android.tonemap.availableToneMapModes")) {
                    obj = 53;
                    break;
                }
                break;
            case 1667056905:
                if (str.equals("android.scaler.availableMaxDigitalZoom")) {
                    obj = 54;
                    break;
                }
                break;
            case 1703534749:
                if (str.equals("android.control.availableSceneModes")) {
                    obj = 55;
                    break;
                }
                break;
            case 1705739614:
                if (str.equals("android.sensor.info.exposureTimeRange")) {
                    obj = 56;
                    break;
                }
                break;
            case 1719695084:
                if (str.equals("android.lens.info.focusDistanceCalibration")) {
                    obj = 57;
                    break;
                }
                break;
            case 1744770529:
                if (str.equals("android.control.maxRegionsAwb")) {
                    obj = 58;
                    break;
                }
                break;
            case 1829266094:
                if (str.equals("android.sync.maxLatency")) {
                    obj = 59;
                    break;
                }
                break;
            case 1918531545:
                if (str.equals("android.control.aeAvailableTargetFpsRanges")) {
                    obj = 60;
                    break;
                }
                break;
            case 2022627910:
                if (str.equals("android.sensor.info.timestampSource")) {
                    obj = 61;
                    break;
                }
                break;
            case 2057483846:
                if (str.equals("android.sensor.info.whiteLevel")) {
                    obj = 62;
                    break;
                }
                break;
        }
        switch (obj) {
            case null:
                return context.getString(2131689691);
            case 1:
                return context.getString(2131689738);
            case 2:
                return context.getString(2131689732);
            case 3:
                return context.getString(2131689724);
            case 4:
                return context.getString(2131689680);
            case 5:
                return context.getString(2131689674);
            case 6:
                return context.getString(2131689726);
            case 7:
                return context.getString(2131689688);
            case 8:
                return context.getString(2131689702);
            case 9:
                return context.getString(2131689690);
            case 10:
                return context.getString(2131689709);
            case 11:
                return context.getString(2131689719);
            case 12:
                return context.getString(2131689694);
            case 13:
                return context.getString(2131689678);
            case 14:
                return context.getString(2131689731);
            case 15:
                return context.getString(2131689701);
            case 16:
                return context.getString(2131689729);
            case 17:
                return context.getString(2131689687);
            case 18:
                return context.getString(2131689734);
            case ConnectionResult.SERVICE_MISSING_PERMISSION /*19*/:
                return context.getString(2131689682);
            case ModuleDescriptor.MODULE_VERSION /*20*/:
                return context.getString(2131689700);
            case 21:
                return context.getString(2131689717);
            case 22:
                return context.getString(2131689723);
            case 23:
                return context.getString(2131689673);
            case 24:
                return context.getString(2131689706);
            case 25:
                return context.getString(2131689707);
            case 26:
                return context.getString(2131689695);
            case AvailableCode.USER_IGNORE_PREVIOUS_POPUP /*27*/:
                return context.getString(2131689716);
            case 28:
                return context.getString(2131689735);
            case 29:
                return context.getString(2131689727);
            case 30:
                return context.getString(2131689705);
            case 31:
                return context.getString(2131689693);
            case 32:
                return context.getString(2131689681);
            case 33:
                return context.getString(2131689713);
            case 34:
                return context.getString(2131689675);
            case 35:
                return context.getString(2131689686);
            case 36:
                return context.getString(2131689699);
            case 37:
                return context.getString(2131689711);
            case 38:
                return context.getString(2131689677);
            case 39:
                return context.getString(2131689730);
            case 40:
                return context.getString(2131689718);
            case 41:
                return context.getString(2131689684);
            case 42:
                return context.getString(2131689689);
            case 43:
                return context.getString(2131689696);
            case 44:
                return context.getString(2131689685);
            case 45:
                return context.getString(2131689703);
            case 46:
                return context.getString(2131689676);
            case 47:
                return context.getString(2131689720);
            case 48:
                return context.getString(2131689715);
            case 49:
                return context.getString(2131689679);
            case 50:
                return context.getString(2131689704);
            case 51:
                return context.getString(2131689725);
            case 52:
                return context.getString(2131689712);
            case 53:
                return context.getString(2131689737);
            case 54:
                return context.getString(2131689710);
            case 55:
                return context.getString(2131689728);
            case 56:
                return context.getString(2131689692);
            case 57:
                return context.getString(2131689697);
            case 58:
                return context.getString(2131689708);
            case 59:
                return context.getString(2131689714);
            case 60:
                return context.getString(2131689733);
            case 61:
                return context.getString(2131689736);
            case 62:
                return context.getString(2131689739);
            default:
                return str;
        }
    }

    public static String z() {
        String S = S("/sys/touchscreen/touch_chip_info");
        if (!TextUtils.isEmpty(S)) {
            return S;
        }
        S = S("/sys/devices/platform/huawei_touch/touch_chip_info");
        if (S != null) {
            S = S.trim();
        }
        if (TextUtils.isEmpty(S)) {
            S = DeviceInfoApp.c.getString(2131690514);
        }
        return S;
    }
}
